//
//  MNDCustomFooterView.m
//  minidai
//
//  Created by Steven.Yung on 2017/6/8.
//  Copyright © 2017年 迷你金服. All rights reserved.
//

#import "MNDCustomFooterView.h"

@implementation MNDCustomFooterView

- (instancetype)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    
    if (self) {
        self.backgroundColor = kColorBackground;
        [self initialButton];
    }
    return self;
}

- (void)initialButton {
    UIButton *button = [UIButton buttonWithType:UIButtonTypeCustom];
    [button setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
    [button setTitle:@"下一步" forState:UIControlStateNormal];
    button.titleLabel.font = [UIFont systemFontOfSize:18.0];
    [button setBackgroundImage:[UIImage imageNamed:@"finance_invest_btn"] forState:UIControlStateNormal];
    
    [self addSubview:button];
    
    button.layer.cornerRadius = 5.0;
    button.layer.masksToBounds = YES;
    
    self.footerButton = button;
    
    [button mas_makeConstraints:^(MASConstraintMaker *make) {
        make.leading.equalTo(self).offset(30.0);
        make.centerX.equalTo(self);
        make.bottom.equalTo(self).offset(-60.0);
        make.height.mas_equalTo(40.0);
    }];
}

@end
